import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:quiver/strings.dart';

extension SizeExtension on num {
  num get w => ScreenUtil().setWidth(this);

  num get h => ScreenUtil().setHeight(this);

  num get sp => ScreenUtil().setSp(this);

  num get ssp => ScreenUtil().setSp(this, allowFontScalingSelf: true);

  num get nsp => ScreenUtil().setSp(this, allowFontScalingSelf: false);
}

extension StringExtension on String {
  bool get notNullOrZero => isNotBlank(this);
}

extension ListExtension on List {
  bool get notZeroSize => this.length != 0;
}
